package com.boot.stomp.client;

import com.boot.web.http.HttpModel;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.cloud.openfeign.SpringQueryMap;
import org.springframework.http.HttpHeaders;
import org.springframework.http.ResponseEntity;
import org.springframework.stereotype.Service;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestHeader;

@Service
@FeignClient(name = "security-service", path = "account", contextId = "account")
public interface AccountClient {

    @GetMapping("/information")
    ResponseEntity<HttpModel<AccountInfo>> getAccountInformation(@SpringQueryMap @RequestHeader(HttpHeaders.AUTHORIZATION) String authorization);

}
